﻿<%@ Page Language="C#" AutoEventWireup="true" CodeFile="update.aspx.cs" Inherits="userbackstage_update1" %>

<!DOCTYPE html>

<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
<meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
    <title></title>
    <style>
        .table{
            width:790px;
            /*height:367px;*/ 
            margin:0 auto;
            text-align:center;
        }
    </style>
</head>
<body>
    <form id="form1" runat="server">
    <div class="table">
   <asp:GridView ID="GridView1" runat="server" CellPadding="3" 
            GridLines="None" AutoGenerateColumns="False" 
            
            onRowEditing="GridView1_RowEditing"
            onRowUpdating="GridView1_RowUpdating"
            onRowCancelingEdit="GridView1_RowCancelingEdit"
            OnPageIndexChanging="GridView1_PageIndexChanging" OnRowDataBound="GridView1_RowDataBound" Width="790px" BackColor="White" BorderColor="White" BorderStyle="Ridge" BorderWidth="2px" CellSpacing="1" PageSize="5" AllowPaging="True">
            <Columns>                
                <asp:TemplateField HeaderText="编号">
                    <ItemTemplate>
                        <%# Eval("id") %>
                    </ItemTemplate>
                </asp:TemplateField>              
                <asp:BoundField HeaderText="信息类型" DataField="type" />
                <asp:BoundField HeaderText="信息标题" DataField="title" />
                <asp:BoundField HeaderText="信息内容" DataField="info" />
                <asp:BoundField DataField="linkman" HeaderText="联系人" />
                <asp:BoundField DataField="tel" HeaderText="联系电话" />
                <%--<asp:BoundField DataField="show" HeaderText="审核状态" ItemStyle-Width="70">
                    <ItemStyle Width="70px"></ItemStyle>
                </asp:BoundField>--%>
                <asp:TemplateField HeaderText="审核状态" ControlStyle-BackColor="Yellow">
                    <ItemTemplate>
                        <%# Convert.ToInt32(Eval("show")) == 0 ? "未审核" :"已审核" %>
                    </ItemTemplate>
                </asp:TemplateField>         
                <asp:CommandField ButtonType="Image" CancelImageUrl="~/Images/BtnCancel.gif" 
                    EditImageUrl="~/Images/BtnUpdate.gif" HeaderText="编辑" ShowEditButton="True" DeleteImageUrl="~/Images/BtnDelete.gif" UpdateImageUrl="~/Images/BtnSave.gif" UpdateText="" />            
                <asp:TemplateField HeaderText="发布者">
                    <ItemTemplate>
                        <%# Eval("release") %>
                    </ItemTemplate>
                </asp:TemplateField>    
            </Columns>
            <FooterStyle BackColor="#C6C3C6" ForeColor="Black" />
            <HeaderStyle BackColor="#4A3C8C" Font-Bold="True" ForeColor="#E7E7FF" />
            <PagerStyle BackColor="#C6C3C6" ForeColor="Black" HorizontalAlign="Right" />
            <RowStyle BackColor="#DEDFDE" ForeColor="Black" />
            <SelectedRowStyle BackColor="#9471DE" Font-Bold="True" ForeColor="White" />
            <SortedAscendingCellStyle BackColor="#F1F1F1" />
            <SortedAscendingHeaderStyle BackColor="#594B9C" />
            <SortedDescendingCellStyle BackColor="#CAC9C9" />
            <SortedDescendingHeaderStyle BackColor="#33276A" />
        </asp:GridView>
    </div>
    </form>
</body>
</html>
